package com.turtle.extend;

import com.turtle.dto.BlogInfoDto;
import com.turtle.dto.BlogParam;
import com.turtle.entity.sql.Blog;
import org.mapstruct.Mapper;
import org.mapstruct.ReportingPolicy;

/**
 * @author lijiayu
 * @date 2020/7/20
 * @description
 */
@Mapper(componentModel = "spring",unmappedTargetPolicy = ReportingPolicy.IGNORE)
public interface BlogConverter {

    Blog toEntity(BlogParam param, Long userId);

    BlogInfoDto toDto(Blog blog);
}
